Favicon

You are here: Home > API Reference > UEM > MDM Policy Template Information > Update mdmSmartAttribute by it"s id

Update mdmSmartAttribute by it"s id

Update mdmSmartAttribute by it"s id

PUT
https://api.applivery.io/v1/organizations/{organizationId}/mdm/devices/smart-attributes
curl -X PUT "https://api.applivery.io/v1/organizations/{organizationId}/mdm/devices/smart-attributes" \
  -H "Authorization: Bearer <YOUR_API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
  "deviceId": "string",
  "deviceType": "emmDevice",
  "smartAttributeId": "string",
  "smartAttributeValue": "string"
}'
const response = await fetch("https://api.applivery.io/v1/organizations/{organizationId}/mdm/devices/smart-attributes", {
  method: "PUT",
  headers: {
    Authorization: "Bearer <YOUR_API_KEY>",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "deviceId": "string",
    "deviceType": "emmDevice",
    "smartAttributeId": "string",
    "smartAttributeValue": "string"
  }),
});

const data = await response.json();
import requests

response = requests.put(
    "https://api.applivery.io/v1/organizations/{organizationId}/mdm/devices/smart-attributes",
    headers={"Authorization": "Bearer <YOUR_API_KEY>"},
    json={
      "deviceId": "string",
      "deviceType": "emmDevice",
      "smartAttributeId": "string",
      "smartAttributeValue": "string"
    },
)

data = response.json()

Request

Send your API key in the request header authorization
Example: Authorization: Bearer <token>

Body Params application/json
deviceId string required
Match pattern: ^[a-fA-F0-9]{24}$
deviceType string required
emmDevice admDevice winDevice aosDevice
smartAttributeId string required
Match pattern: ^[a-fA-F0-9]{24}$
smartAttributeValue string required
≤ 1000 characters
{
    "deviceId": "string",
    "deviceType": "emmDevice",
    "smartAttributeId": "string",
    "smartAttributeValue": "string"
}

Responses

200 Response application/json
status boolean required
data object required
id string required
Match pattern: ^[a-fA-F0-9]{24}$
label string optional
≤ 256 characters
type string required
constant enum manual selector script
value any required
override any optional
updatedAt string required
{
    "status": true,
    "data": {
        "id": "string",
        "label": "string",
        "type": "constant",
        "value": "string",
        "override": "string",
        "updatedAt": "string"
    }
}
400 Response application/json
status boolean optional
false
error object optional
code number optional
5120
message string optional
Error updating entity
{
    "status": false,
    "error": {
        "code": 5221,
        "message": "Unable to process smart attribute request"
    }
}
401 Response application/json
status boolean optional
false
error object optional
code number optional
4004
message string optional
Invalid Token
{
    "status": false,
    "error": {
        "code": 4002,
        "message": "No auth token"
    }
}
404 Response application/json
status boolean optional
false
error object optional
code number optional
3001
message string optional
Entity not found
{
    "status": false,
    "error": {
        "code": 3001,
        "message": "Entity not found"
    }
}